---
title: Test
---

Hey!

```tsx
'use client';

import { useChat } from 'ai/react';

export default function Chat() {
  const { messages, input, handleInputChange, handleSubmit } = useChat({
    maxSteps: 5, // [!code highlight]
  });

  // ... rest of your component code
}
```
